# 已知字符串 test = "aAsmr3idd4bgs7Dlsf9eAF",将字符串中的数字取出，生成一个新的字符串
import re
test = "aAsmr3idd4bgs7Dlsf9eAF"
new_test = ''.join(re.findall(r'\d+', test))
print(new_test)